/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package Model;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlRootElement;

/**
 *
 * @author Christian
 */
@Entity
@Table(name = "BOLSA")
@XmlRootElement
@NamedQueries({
    @NamedQuery(name = "Bolsa.findAll", query = "SELECT b FROM Bolsa b"),
    @NamedQuery(name = "Bolsa.findByTitulo", query = "SELECT b FROM Bolsa b WHERE b.titulo = :titulo"),
    @NamedQuery(name = "Bolsa.findByDescricao", query = "SELECT b FROM Bolsa b WHERE b.descricao = :descricao"),
    @NamedQuery(name = "Bolsa.findByLocall", query = "SELECT b FROM Bolsa b WHERE b.locall = :locall"),
    @NamedQuery(name = "Bolsa.findByContato", query = "SELECT b FROM Bolsa b WHERE b.contato = :contato"),
    @NamedQuery(name = "Bolsa.findByCargahoraria", query = "SELECT b FROM Bolsa b WHERE b.cargahoraria = :cargahoraria"),
    @NamedQuery(name = "Bolsa.findByDura\u00e7\u00e3o", query = "SELECT b FROM Bolsa b WHERE b.dura\u00e7\u00e3o = :dura\u00e7\u00e3o"),
    @NamedQuery(name = "Bolsa.findByNomelattes", query = "SELECT b FROM Bolsa b WHERE b.nomelattes = :nomelattes"),
    @NamedQuery(name = "Bolsa.findByEndlattes", query = "SELECT b FROM Bolsa b WHERE b.endlattes = :endlattes"),
    @NamedQuery(name = "Bolsa.findByValor", query = "SELECT b FROM Bolsa b WHERE b.valor = :valor")})
public class Bolsa implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @Basic(optional = false)
    @Column(name = "TITULO")
    private String titulo;
    @Column(name = "DESCRICAO")
    private String descricao;
    @Column(name = "LOCALL")
    private String locall;
    @Column(name = "CONTATO")
    private String contato;
    @Column(name = "CARGAHORARIA")
    private Integer cargahoraria;
    @Column(name = "DURA\u00c7\u00c3O")
    private Integer duração;
    @Column(name = "NOMELATTES")
    private String nomelattes;
    @Column(name = "ENDLATTES")
    private String endlattes;
    // @Max(value=?)  @Min(value=?)//if you know range of your decimal fields consider using these annotations to enforce field validation
    @Column(name = "VALOR")
    private Double valor;

    public Bolsa() {
    }

    public Bolsa(String titulo) {
        this.titulo = titulo;
    }

    public String getTitulo() {
        return titulo;
    }

    public void setTitulo(String titulo) {
        this.titulo = titulo;
    }

    public String getDescricao() {
        return descricao;
    }

    public void setDescricao(String descricao) {
        this.descricao = descricao;
    }

    public String getLocall() {
        return locall;
    }

    public void setLocall(String locall) {
        this.locall = locall;
    }

    public String getContato() {
        return contato;
    }

    public void setContato(String contato) {
        this.contato = contato;
    }

    public Integer getCargahoraria() {
        return cargahoraria;
    }

    public void setCargahoraria(Integer cargahoraria) {
        this.cargahoraria = cargahoraria;
    }

    public Integer getDuração() {
        return duração;
    }

    public void setDuração(Integer duração) {
        this.duração = duração;
    }

    public String getNomelattes() {
        return nomelattes;
    }

    public void setNomelattes(String nomelattes) {
        this.nomelattes = nomelattes;
    }

    public String getEndlattes() {
        return endlattes;
    }

    public void setEndlattes(String endlattes) {
        this.endlattes = endlattes;
    }

    public Double getValor() {
        return valor;
    }

    public void setValor(Double valor) {
        this.valor = valor;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (titulo != null ? titulo.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof Bolsa)) {
            return false;
        }
        Bolsa other = (Bolsa) object;
        if ((this.titulo != null || other.titulo == null) && (this.titulo == null || this.titulo.equals(other.titulo))) {
        } else {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "principal.Bolsa[ titulo=" + titulo + " ]";
    }
    
}
